-
Notifications
You must be signed in to change notification settings - Fork 13
refactor: Move arrow key shortcuts into their own class. #304
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
rachel-fenichel
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Note: hold off on merging until Ben's current focus changes land.
cpcallen
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Per my remarks on #274—see also this lengthy discussion about cursor actions—I think the actions should be named after the cursor keys they are bound to.
(And we should in due course refactor the cursors so that their APIs are also directional, with each cursor being responsible for mapping from arrow direction to AST directions depending on LTR, flyout layout, etc.)
|
To be clear, you want separate |
cpcallen
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
To be clear, you want separate
LeftAction,RightAction,UpActionandDownActionclasses/files?
No, not at all. I just think we should rename the actions (id, name, description, etc.) to up/down/left/right, rather than prev/next/out/in.
(I think we should also rename the corresponding methods on the cursors, but that can be done as part of a subsequent PR that actually makes them RTL / horizontal flyout aware.)
|
Got it, thanks for clarifying! Updated accordingly (and also removed other deleted actions from |
This PR fixes #296 by moving the left/right/up/down arrow key actions out of navigation_controller.ts and into their own class.